// Shortcut for getElementById()
function $(which) {
	return document.getElementById(which);
}

// Animate showing/hiding an element.
function blind(target) {
	var element = document.getElementById(target);
	
	// Animate showing
	if (element.getStyle('display') == 'none') {
		Animation(element).to('height', 'auto').from('0px').to('opacity', 1).from(0).show().ease(Animation.ease.end).blind().go();
	}
	// Animate hiding
	else {
		Animation(element).to('height', '0px').to('opacity', 0).hide().ease(Animation.ease.end).blind().go();
	}
}

// Prevent the default event from firing
function preventDefault(event) {
	event.preventDefault();
}